package com.ciquan.server.service.impl;

import com.ciquan.server.bean.Advertisement;
import com.ciquan.server.dao.AdvertisementMapper;
import com.ciquan.server.service.AdvertisementService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

/**
 * Created by kakalee on 15/3/27.
 */
@Service
public class AdvertisementServiceImpl implements AdvertisementService {

    @Resource
    private AdvertisementMapper advertisementMapper;

    @Override
    public int insert(Advertisement advertisement) {
        return advertisementMapper.insert(advertisement);
    }

    @Override
    public Advertisement selectById(int id) {
        return advertisementMapper.selectById(id);
    }

    @Override
    public List<Advertisement> selectList() {
        return advertisementMapper.selectList();
    }

    @Override
    public int update(Advertisement advertisement) {
        return advertisementMapper.update(advertisement);
    }
}
